package com.mp.service.impl;/**
 * @author MRD
 * 2019/8/26
 */

import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.mp.dao.WebsiteFlyRecordMapper;
import com.mp.pojo.NO.WebsiteFlyRecordNO;
import com.mp.pojo.Query.WebsiteFlyRecordQuery;
import com.mp.pojo.VO.WebsiteFlyRecordVO;
import com.mp.pojo.WebsiteFlyRecord;
import com.mp.service.WebsiteFlyRecordService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

/**
 *@description:
 *@author: Ace
 *@create: 2019-08-26 17:07
 */
@Service
public class WebsiteFlyRecordServiceImpl extends ServiceImpl<WebsiteFlyRecordMapper,WebsiteFlyRecord> implements WebsiteFlyRecordService {

    @Autowired
    private WebsiteFlyRecordMapper websiteFlyRecordMapper;


    /**
     * 飞单分页记录
     * @param flyRecord
     * @return
     */
    @Override
    public IPage<WebsiteFlyRecordVO> pageWebsiteFlyRecord(WebsiteFlyRecordNO flyRecord) {
        Page<WebsiteFlyRecordVO> page = new Page<>(flyRecord.getCurrent(),flyRecord.getSize());
        return websiteFlyRecordMapper.pageWebsiteFlyRecord(page,flyRecord.getWebsiteUserId(),flyRecord.getCode());
    }
}
